DataWeave Playground License Agreement
By accessing and using this DataWeave Playground, you agree to the DataWeave Playground Commercial Free License Agreement located here.
You also agree that you will not submit any personal data or personally identifiable information, personal health data, or other sensitive or regulated data into the DataWeave Playground and that MuleSoft may store, monitor, track, or inspect data that is accessible by the DataWeave Playground.
Expression Type: DateTime
Returns a DateTime value for the current date and time.
This example uses now() to return the current date and time as a
DateTime value. It also shows how to return a date and time
in a specific time zone. Java 8 time zones are supported.
This example shows uses of the now() function with valid
selectors. It also shows how to get the epoch time with now() as Number.
For additional examples, see
Date and Time (dw::Core Types).